<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <link rel="stylesheet" href="bs/css/bootstrap.min.css" />
    <script src="js/vue.global.js"></script>
    <script src="js/axios.min.js"></script>
    <style type="text/css">
      table tr th {
        font-weight: 700px;
        color: red;
        background-color: blueviolet;
      }
      h1 {
        color: red;
      }
    </style>
    <title>Document</title>
  </head>
  <body>
    <div id="app">
      <h1>你好石雨涵</h1>
      <div>{{message}}</div>

      <button class="btn btn-primary" onclick="test()">点我</button>
      <button @click="test" class="btn btn-danger">变变变</button>
      <table class="table table-bordered">
        <tr>
          <th>学号</th>
          <th>姓名</th>
          <th>年龄</th>
        </tr>
        <tr>
          <td>1</td>
          <td>石雨涵</td>
          <td>14</td>
        </tr>
        <tr>
          <td>1</td>
          <td>石雨涵</td>
          <td>14</td>
        </tr>
        <tr>
          <td>1</td>
          <td>石雨涵</td>
          <td>14</td>
        </tr>
        <tr>
          <td>2</td>
          <td>石雨涵</td>
          <td>15</td>
        </tr>
      </table>
    </div>

    <script>
      const { createApp } = Vue;

      createApp({
        data() {
          return {
            message: "石金峰",
          };
        },
        methods: {
          test() {
            if ((this.message = "石金峰")) {
              this.message = "你好";
            } else {
              this.message = "石金峰";
            }
          },
        },
      }).mount("#app");

      function test() {
        alert("你好石雨涵");
      }
    </script>
  </body>
</html>
